<ui:composition xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:pe="http://primefaces.org/ui/extensions"
	xmlns:p="http://primefaces.org/ui" template="/bootstraplayout.xhtml">


	<ui:define name="title">
		<h:outputText value="New Application" />

	</ui:define>



	<ui:define name="toptoolbar">

		<ui:include src="authenticatedtoolbar.xhtml" />

	</ui:define>

	<ui:define name="navigation">
		<p:menu>
			<p:submenu label="Actions">
				<p:menuitem value="View Applications" outcome="applications.jsf"
					icon="ui-icon-star" />
					
				<p:menuitem value="Add Application" outcome="newapplication.jsf"
					icon="ui-icon-star" />
					
			
			</p:submenu>
			
		</p:menu>
	</ui:define>

	<ui:define name="mainform">
		<p:panel header="New Application" id="newapplication">
			<p:messages id="messages" showSummary="true" />

			<h:panelGrid columns="2" id="dynaFormGroup" layout="block"
				style="margin-top: 15px;">


				<p:outputLabel value="Name:" for="name" />

				<p:inputText id="name" size="100"
					value="#{newApplicationForm.application.name}" required="true" style="width:75%"/>


				<p:outputLabel value="Description:" for="description" />

				<p:inputTextarea rows="4" cols="20" id="description" style="width:75%" 
					value="#{newApplicationForm.application.description}" />


			</h:panelGrid>

			<p:commandButton value="Save" style="margin-right:20px;"
				icon="ui-icon-disk"  action="#{newApplicationForm.save}" update="newapplication" process="newapplication"
				styleClass="ui-btn-success" />
			<p:commandButton type="reset" value="#{msg.reset}"
				style="margin-left: 5px;" />

		</p:panel>



	</ui:define>



</ui:composition>